package org.zjx.task.exception;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 任务链执行异常（受检异常）
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class ChainExecutionException extends Exception {
    private final String chainId;
    private final int interruptPosition;

    public ChainExecutionException(String message, String chainId, int position) {
        super(message + " [ChainID:" + chainId + "]");
        this.chainId = chainId;
        this.interruptPosition = position;
    }
}